| BackMode Property |
Returns/sets the background mode of the Treeview control to Normal, Color or Graphic mode.
Syntax
object.BackMode [=value]
The BackMode property syntax has these parts:
| Part | Description |
|---|---|
| object | Required. An object expression that evaluates to an object in the Applies To list. |
| value | A value or constant that determines the background mode, as described in Settings. |
Settings
The BackMode property settings are:
| Constant | Setting | Description |
|---|---|---|
| bmDefault | 0 | Disables custom background draw mode (fastest). |
| bmColor | 1 | Allows the TreeView backgrond color to be changed. |
| bmGraphic | 2 | Displays a referenced STDPicture object or loads and displays a BMP/JPG/GIF file into the background of the TreeView control. |
Remarks
bmColor and bmGraphic modes will not affect the custom colors for all Node objects in the TreeView control.
Data Type
eBackMode
Example
| ' '## Note: oTree is a reference to the vbTree.cTreeView class ' '## Load Graphic Background image from file ' With oTree .Backmode = bmGraphic .BackFileName = App.Path + "\TreeBack.Gif" End With |
| ' '## Note: oTree is a reference to the vbTree.cTreeView class ' '## Set Background color to ToolTip BackColor ' With oTree .Backmode = bmColor .BackColor = vbInfoBackground End With |